package JunitTest;

import org.junit.Assert;
import org.junit.BeforeClass;
import org.junit.Test;


public class TestJunit {
    private static Rectangle rectangle;
    @BeforeClass
    public static void init(){
       rectangle = new Rectangle(10,20);
    }
    @Test
    public void testGetArea(){
        Integer area = rectangle.getArea();
        Assert.assertEquals("面积计算的不准确",
                200,
                area.longValue());
    }
}